//package com.example.rwq_test.webrtc1;
//
//public class UserSession {
//    private Process process;  // 遗留
//    private Process videoProcess;
//    private Process audioProcess;
//    private int rtpPort;  // 遗留
//    private int audioPort;
//    private int videoPort;
//
//    public void setProcess(Process p) { this.process = p; }  // 遗留
//    public Process getProcess() { return process; }
//
//    public void setVideoProcess(Process p) { this.videoProcess = p; }
//    public Process getVideoProcess() { return videoProcess; }
//
//    public void setAudioProcess(Process p) { this.audioProcess = p; }
//    public Process getAudioProcess() { return audioProcess; }
//
//    public void setRtpPort(int port) { this.rtpPort = port; }
//    public int getRtpPort() { return rtpPort; }
//
//    public void setAudioPort(int port) { this.audioPort = port; }
//    public int getAudioPort() { return audioPort; }
//
//    public void setVideoPort(int port) { this.videoPort = port; }
//    public int getVideoPort() { return videoPort; }
//
//    public void release() {
//        if (videoProcess != null) {
//            videoProcess.destroyForcibly();
//            try {
//                videoProcess.waitFor();
//            } catch (InterruptedException e) {
//                Thread.currentThread().interrupt();
//            }
//        }
//        if (audioProcess != null) {
//            audioProcess.destroyForcibly();
//            try {
//                audioProcess.waitFor();
//            } catch (InterruptedException e) {
//                Thread.currentThread().interrupt();
//            }
//        }
//        if (process != null) {  // 遗留
//            process.destroyForcibly();
//            try {
//                process.waitFor();
//            } catch (InterruptedException e) {
//                Thread.currentThread().interrupt();
//            }
//        }
//    }
//}